/**
 * @Project Name:hoofungson-life
 * @Package Name:cn.hoofungson.life.core.model.entity
 * @Since JDK 1.8
 */
package cn.hoofungson.blog.business.service.provider.model.entity.user;

import cn.hoofungson.blog.business.service.interfaces.enums.user.UserSex;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.hibernate.annotations.GenericGenerator;

import javax.persistence.*;
import java.io.Serializable;
import java.util.Date;

/**
 * @Description: 用户实体
 * @Author 胡松 hoofungson@163.com
 * @Date 2017-12-21 10:53
 * @Version V1.0
 */
@Data
@NoArgsConstructor
@Entity
@Table(name = "hb_user")
public class UserPO implements Serializable {

    @Id
    @GenericGenerator(name = "user_generator", strategy = "increment")
    @GeneratedValue(strategy = GenerationType.IDENTITY, generator = "user_generator")
    private Long id;
    @Column(name = "user_name")
    private String username;
    @Column(name = "password")
    private String password;
    @Column(name = "real_name")
    private String realName;
    @Column(name = "sex")
    @Enumerated(EnumType.STRING)
    private UserSex sex;
    @Column(name = "birthday")
    private Date birthday;
    @Column(name = "hometown")
    private String hometown;
    @Column(name = "address")
    private String address;
    @Column(name = "email")
    private String email;
    @Column(name = "call_num")
    private String call;
    @Column(name = "phone")
    private String phone;
    @Column(name = "qq")
    private String qq;
    @Column(name = "enabled")
    private Boolean enabled;
    @Column(name = "account_non_expired")
    private Boolean accountNonExpired;
    @Column(name = "account_non_locked")
    private Boolean accountNonLocked;
    @Column(name = "credentials_non_expired")
    private Boolean credentialsNonExpired;
    @Column(name = "create_time")
    private Date createTime;
    @Column(name = "update_time")
    private Date updateTime;

}
